﻿CREATE TABLE [PR].[ContragentVsContragents] (
    [Id]                 INT IDENTITY (1, 1) NOT NULL,
    [ParentContragentId] INT NOT NULL,
    [ChildContragentId]  INT NOT NULL,
    CONSTRAINT [PK_ContragentVsContragents] PRIMARY KEY CLUSTERED ([Id] ASC),
    CONSTRAINT [IX_ContragentVsContragents_2] UNIQUE NONCLUSTERED ([ChildContragentId] ASC, [ParentContragentId] ASC)
);

